
pkgname=libpsl
pkgver=0.20.1
pkgrel=2
pkgdesc="Library that provides functions to work with the Mozilla Public Suffix List."
arch=('x86_64')
url="https://rockdaboot.github.io/libpsl/"
license=('MIT')
depends=('libidn' 'libunistring')
makedepends=('python2')
source=("https://github.com/rockdaboot/libpsl/releases/download/${pkgname}-${pkgver}/${pkgname}-${pkgver}.tar.gz")
md5sums=('699f2ae7b20c78b2b65c6adce55de2e9')

build() {
  cd ${pkgname}-${pkgver}
  
  ./configure \
    --prefix=/usr \
    --disable-static \
    --disable-dependency-tracking \
    --enable-man \
    --enable-builtin=libidn \
    --enable-runtime=libidn

  make
}

package() {
  cd ${pkgname}-${pkgver}
  make DESTDIR=${pkgdir} install

  install -m755 -d ${pkgdir}/usr/share/licenses/libpsl
  install -m644 COPYING ${pkgdir}/usr/share/licenses/libpsl/
}

